<!-- This comment will put IE 6, 7 and 8 in quirks mode -->
<!DOCTYPE html PUBLIC "-//W3C//DTD XHTML 1.0 Transitional//EN" "http://www.w3.org/TR/xhtml1/DTD/xhtml1-transitional.dtd">
<html xmlns="http://www.w3.org/1999/xhtml">
<head>
<meta http-equiv="Content-Type" content="text/xhtml;charset=UTF-8"/>
<title>FEUP-Defender: rtc/rtc_isr.h Source File</title>
<link href="../../tabs.css" rel="stylesheet" type="text/css"/>
<link href="../../search/search.css" rel="stylesheet" type="text/css"/>
<script type="text/javaScript" src="../../search/search.js"></script>
<link href="../../doxygen.css" rel="stylesheet" type="text/css"/>
</head>
<body onload='searchBox.OnSelectItem(0);'>
<!-- Gerado por Doxygen 1.6.3 -->
<script type="text/javascript"><!--
var searchBox = new SearchBox("searchBox", "../../search",false,'Localizar');
--></script>
<script type="text/javascript">
<!--
function changeDisplayState (e){
  var num=this.id.replace(/[^[0-9]/g,'');
  var button=this.firstChild;
  var sectionDiv=document.getElementById('dynsection'+num);
  if (sectionDiv.style.display=='none'||sectionDiv.style.display==''){
    sectionDiv.style.display='block';
    button.src='../../open.gif';
  }else{
    sectionDiv.style.display='none';
    button.src='../../closed.gif';
  }
}
function initDynSections(){
  var divs=document.getElementsByTagName('div');
  var sectionCounter=1;
  for(var i=0;i<divs.length-1;i++){
    if(divs[i].className=='dynheader'&&divs[i+1].className=='dynsection'){
      var header=divs[i];
      var section=divs[i+1];
      var button=header.firstChild;
      if (button!='IMG'){
        divs[i].insertBefore(document.createTextNode(' '),divs[i].firstChild);
        button=document.createElement('img');
        divs[i].insertBefore(button,divs[i].firstChild);
      }
      header.style.cursor='pointer';
      header.onclick=changeDisplayState;
      header.id='dynheader'+sectionCounter;
      button.src='../../closed.gif';
      section.id='dynsection'+sectionCounter;
      section.style.display='none';
      section.style.marginLeft='14px';
      sectionCounter++;
    }
  }
}
window.onload = initDynSections;
-->
</script>
<div class="navigation" id="top">
  <div class="tabs">
    <ul>
      <li><a href="../../index.html"><span>Página&nbsp;principal</span></a></li>
      <li><a href="../../modules.html"><span>Módulos</span></a></li>
      <li><a href="../../annotated.html"><span>Estruturas&nbsp;de&nbsp;dados</span></a></li>
      <li class="current"><a href="../../files.html"><span>Ficheiros</span></a></li>
      <li><a href="../../dirs.html"><span>Directories</span></a></li>
      <li>
        <div id="MSearchBox" class="MSearchBoxInactive">
        <img id="MSearchSelect" src="../../search/search.png"
             onmouseover="return searchBox.OnSearchSelectShow()"
             onmouseout="return searchBox.OnSearchSelectHide()"
             alt=""/>
        <input type="text" id="MSearchField" value="Localizar" accesskey="S"
             onfocus="searchBox.OnSearchFieldFocus(true)" 
             onblur="searchBox.OnSearchFieldFocus(false)" 
             onkeyup="searchBox.OnSearchFieldChange(event)"/>
        <a id="MSearchClose" href="javascript:searchBox.CloseResultsWindow()"><img id="MSearchCloseImg" border="0" src="../../search/close.png" alt=""/></a>
        </div>
      </li>
    </ul>
  </div>
  <div class="tabs">
    <ul>
      <li><a href="../../files.html"><span>Lista&nbsp;de&nbsp;ficheiros</span></a></li>
      <li><a href="../../globals.html"><span>Globais</span></a></li>
    </ul>
  </div>
  <div class="navpath"><a class="el" href="../../dir_ef7cd746c6b5f6b8ac4964fa3cf2d2e6.html">rtc</a>
  </div>
</div>
<div class="contents">
<h1>rtc_isr.h</h1><a href="../../d4/dbb/rtc__isr_8h.html">Ir para a documentação deste ficheiro.</a><div class="fragment"><pre class="fragment"><a name="l00001"></a>00001 <span class="preprocessor">#include &quot;<a class="code" href="../../dc/d1b/rtc_8h.html">rtc.h</a>&quot;</span>
<a name="l00002"></a>00002 <span class="preprocessor">#include &quot;<a class="code" href="../../db/d10/music_8h.html">music.h</a>&quot;</span>
<a name="l00003"></a>00003 <span class="preprocessor">#include &quot;GQueue.h&quot;</span>
<a name="l00004"></a>00004 
<a name="l00005"></a>00005 <span class="keyword">extern</span> <a class="code" href="../../d3/d97/structSong.html">Song</a>* <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a408a4ba6c0e1bfcced812732028b0d63">bgm</a>;
<a name="l00006"></a>00006 <span class="keyword">extern</span> GQueue* <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a38142e8cc56eef456a3b7d5239a538c8">music_queue</a>;
<a name="l00007"></a>00007 
<a name="l00008"></a><a class="code" href="../../d4/dbb/rtc__isr_8h.html#a012c4982a1a7b2d0d2fb671ce12f2129a948b2aee15f52b421fa4770c47bcfe8c">00008</a> <span class="keyword">typedef</span> <span class="keyword">enum</span> {<a class="code" href="../../d4/dbb/rtc__isr_8h.html#a012c4982a1a7b2d0d2fb671ce12f2129a3ff8ba88da6f8947ab7c22b7825c6bb6">INACTIVE</a>, <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a012c4982a1a7b2d0d2fb671ce12f2129a0352906d1ea1dfcd663c918f3a86755b">PLAY</a>, <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a012c4982a1a7b2d0d2fb671ce12f2129a56b36d0d0bb01b339cf1041adc08e262">PAUSE</a>, <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a012c4982a1a7b2d0d2fb671ce12f2129a948b2aee15f52b421fa4770c47bcfe8c">STOPPED</a>} <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a012c4982a1a7b2d0d2fb671ce12f2129">MUSIC_STATE</a>;
<a name="l00009"></a><a class="code" href="../../d4/dbb/rtc__isr_8h.html#ad7bbf22d5b2e6b1476016c142946e2a7">00009</a> <span class="keyword">volatile</span> <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a012c4982a1a7b2d0d2fb671ce12f2129">MUSIC_STATE</a> <a class="code" href="../../d4/dbb/rtc__isr_8h.html#ad7bbf22d5b2e6b1476016c142946e2a7">state</a> = <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a012c4982a1a7b2d0d2fb671ce12f2129a3ff8ba88da6f8947ab7c22b7825c6bb6">INACTIVE</a>;
<a name="l00010"></a><a class="code" href="../../d4/dbb/rtc__isr_8h.html#a12795655af98a0e241784ed41d6b75f8">00010</a> <span class="keyword">volatile</span> <span class="keywordtype">int</span> <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a12795655af98a0e241784ed41d6b75f8">ms_count</a> = 0;
<a name="l00011"></a>00011 
<a name="l00012"></a><a class="code" href="../../d4/dbb/rtc__isr_8h.html#a408a4ba6c0e1bfcced812732028b0d63">00012</a> <span class="keyword">extern</span> <a class="code" href="../../d3/d97/structSong.html">Song</a>* bgm;
<a name="l00013"></a><a class="code" href="../../d4/dbb/rtc__isr_8h.html#a6a427886bdf6c263a14ca33850dd03d9">00013</a> <span class="keywordtype">int</span> <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a6a427886bdf6c263a14ca33850dd03d9">song_ind</a> = 0;
<a name="l00014"></a><a class="code" href="../../d4/dbb/rtc__isr_8h.html#a0b8bf56317cbad112f3a671ac52d3249">00014</a> <a class="code" href="../../d8/db9/group__UserTypes.html#ga39db6982619d623273fad8a383489309">Bool</a> <a class="code" href="../../d4/dbb/rtc__isr_8h.html#a0b8bf56317cbad112f3a671ac52d3249">song_loop</a> = <span class="keyword">false</span>;
<a name="l00015"></a>00015 
<a name="l00016"></a>00016 <span class="keywordtype">void</span> <a class="code" href="../../d7/d3c/rtc__isr_8c.html#aa4f18104015de13014524989b16db6c4">rtc_isr</a>(<span class="keywordtype">void</span>);
</pre></div></div>
<!--- window showing the filter options -->
<div id="MSearchSelectWindow"
     onmouseover="return searchBox.OnSearchSelectShow()"
     onmouseout="return searchBox.OnSearchSelectHide()"
     onkeydown="return searchBox.OnSearchSelectKey(event)">
<a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(0)"><span class="SelectionMark">&nbsp;</span>Tudo</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(1)"><span class="SelectionMark">&nbsp;</span>Estruturas de dados</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(2)"><span class="SelectionMark">&nbsp;</span>Ficheiros</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(3)"><span class="SelectionMark">&nbsp;</span>Funções</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(4)"><span class="SelectionMark">&nbsp;</span>Variáveis</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(5)"><span class="SelectionMark">&nbsp;</span>Definições de tipos</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(6)"><span class="SelectionMark">&nbsp;</span>Enumerações</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(7)"><span class="SelectionMark">&nbsp;</span>Valores da enumeração</a><a class="SelectItem" href="javascript:void(0)" onclick="searchBox.OnSelectItem(8)"><span class="SelectionMark">&nbsp;</span>Macros</a></div>

<!-- iframe showing the search results (closed by default) -->
<div id="MSearchResultsWindow">
<iframe src="" frameborder="0" 
        name="MSearchResults" id="MSearchResults">
</iframe>
</div>

<hr class="footer"/><address style="text-align: right;"><small>Gerado em Tue Jun 1 21:46:45 2010 para FEUP-Defender por&nbsp;
<a href="http://www.doxygen.org/index.html">
<img class="footer" src="../../doxygen.png" alt="doxygen"/></a> 1.6.3 </small></address>
</body>
</html>
